<?xml version='1.0' encoding='UTF-8' ?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
      xmlns:h="http://java.sun.com/jsf/html"
      xmlns:f="http://java.sun.com/jsf/core"
      xmlns:ui="http://java.sun.com/jsf/facelets">
    <h:head>
        <title>#{displayUserBean.username}</title>
    </h:head>
    <h:body>
        <ui:composition template="/Template/newTemplate.xhtml">
            <ui:define name="content">
                <h:form>
                    <h:commandLink action="#{managerBean.stalkOrUnstalkFriend(displayUserBean.id)}" value="#{managerBean.stalkable(displayUserBean.id)}"></h:commandLink>
                </h:form>
                <table>
                    <tr>
                        <td><b>Username:</b></td>
                        <td>#{displayUserBean.username}</td>
                    </tr>
                    <tr>
                        <td><b>Address:</b></td>
                        <td>#{displayUserBean.address}</td>
                    </tr>
                    <tr>
                        <td><b>Zipcode:</b></td>
                        <td>#{displayUserBean.zipcode}</td>
                    </tr>
                    <tr>
                        <td><b>City:</b></td>
                        <td>#{displayUserBean.city}</td>
                    </tr>
                    <tr>
                        <td><b>Country:</b></td>
                        <td>#{displayUserBean.country}</td>
                    </tr>
                </table>
                <br></br>
                <b>Postits:</b>
                <h:dataTable value="#{displayUserBean.postits}" var="post">
                    <h:column>
                        <h:outputText value="#{post.userId.username}"></h:outputText>
                    </h:column>
                    <h:column>
                        <h:outputText value="#{post.datePosted}"></h:outputText>
                    </h:column>
                    <h:column>
                        <h:outputText value="#{post.content}"></h:outputText>
                    </h:column>
                </h:dataTable>
            </ui:define>
        </ui:composition>
    </h:body>
</html>

